<template>
  <a-spin
    :spinning="spinning"
    class="spin"
    style="background-color: rgb(240, 242, 245)"
  >
    <div class="massage" style="background-color: rgb(240, 242, 245)">
      <a-collapse default-active-key="1" :bordered="false">
        <template #expandIcon="props">
          <a-icon type="double-right" :rotate="props.isActive ? 90 : 0" />
        </template>
        <a-collapse-panel key="1" header="个人基本信息" :style="customStyle">
          <div class="form">
            <everdayFormNoRowAntcol
              :formItem="userMessageForItem"
              :beforeCreate="everdayform"
              :labelcol="{ span: 8 }"
            >
              <!-- <template #fyhkh="data">
                <div style="display: flex; align-items: center">
                  <a-input
                    :type="showNameIs ? 'text' : 'password'"
                    v-decorator="[`${data.model}`]"
                  ></a-input
                  ><a-icon
                    @click="showNameIs = !showNameIs"
                    :type="showNameIs ? 'eye-invisible' : 'eye'"
                  />
                </div>
              </template> -->
              <template #save>
                <div class="box-center" style="margin-top: 20px;">
                  <a-button @click="saveUser" type="primary" class="blue-btn"  style="margin-left: 10px;">
                    保存
                  </a-button>
                  <a-button
                    style="margin-left: 15px;"
                    @click="clickDownloadFile('个人签名')"
                    type="primary"
                    class="blue-btn"
                    ><a-icon type="download" /> 导出个人签名
                  </a-button>
                  <a-button
                    @click="handlerUserSignature('个人签名')"
                    style="margin-left: 15px;"
                    type="primary"
                    class="blue-btn"
                    ><a-icon type="import" /> 导入个人签名
                  </a-button>

                  <a-button 
                  v-if="inspectorId.id"
                  style="margin-left: 15px;" 
                  class="blue-btn" type="primary" 
                  @click="modifyPassword('重置密码',
                  {url:assessCheckApi.resetHcyPwd,method:'get',params:{fuserid:inspectorId.fuserid}},
                  'params','')">重置密码</a-button>

                  <a-button 
                  v-if="inspectorId.id"
                  style="margin-left: 15px;" 
                  class="blue-btn" type="primary" 
                  @click="modifyClick('账号',
                  {url:assessCheckApi.modifyHcyAccount,method:'put',data:{fuserid:inspectorId.fuserid,username:form.getFieldValue('username'),}},
                  'data','username','')">修改账号</a-button>
                  <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('执勤状态',
                      {url:assessCheckApi.modifyHcyGzzt,method:'put',data:{fuserid:inspectorId.fuserid,fgzzt:form.getFieldValue('fgzzt')}},
                      'data','fgzzt','核查员工作状态')">修改执勤状态</a-button>
                  </div>
              </template>
            </everdayFormNoRowAntcol>
          </div>
        </a-collapse-panel>
        <a-collapse-panel key="2" header="审评员信息" :style="customStyle">
          <!-- 药品生产审评员 -->
          <a-collapse default-active-key="3">
            <a-collapse-panel
              key="3"
              header="药品生产审评员"
              v-if="ypscHcyformData"
            >
              <div>
                <everdayFormNoRowAntcol
                  :key="inspectorKey"
                  className="form-item-bottom-num"
                  :formItem="ypscHcyForItems"
                  :beforeCreate="ypscHcyFor"
                  :labelcol="{ span: 8 }"
                >
                  <template #save>
                    <div style="margin-left: 120px;margin-top: 20px;">
                      <a-button
                        class="blue-btn"
                        @click="saveHcy(ypscHcyform, ypscHcyformData)"
                        type="primary"
                      >
                        保存
                      </a-button>
                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('所属库',
                      {url:assessCheckApi.modifyHcySsk,method:'put',
                      data:{id:ypscHcyformData['id'],fssk:ypscHcyform.getFieldValue('fssk')}},
                      'data','fssk','核查员所属库','ypscHcyform')">修改所属库</a-button>

                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('有效状态',
                      {url:assessCheckApi.modifyHcyState,method:'put',
                      data:{id:ypscHcyformData['id'],fstate:ypscHcyform.getFieldValue('fstate')}},
                      'data','fstate','核查员有效状态','ypscHcyform')">修改有效状态</a-button>
                    </div>
                  </template>
                </everdayFormNoRowAntcol>
              </div>
            </a-collapse-panel>
            <!-- 药品流通核查员 -->
            <a-collapse-panel
              key="4"
              header="药品流通审评员"
              v-if="ypltHcyFormData"
            >
              <everdayFormNoRowAntcol
                :key="inspectorKey"
                :formItem="ypltHcyFotItems"
                :beforeCreate="ypltHcyFor"
                :labelcol="{ span: 8 }"
              >
                <template #save>
                  <div style="margin-left: 120px;margin-top: 20px;">
                    <a-button
                      @click="saveHcy(ypltHcyForm, ypltHcyFormData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>

                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('所属库',
                      {url:assessCheckApi.modifyHcySsk,method:'put',
                      data:{id:ypltHcyFormData['id'],fssk:ypltHcyForm.getFieldValue('fssk')}},
                      'data','fssk','核查员所属库','ypltHcyForm')">修改所属库</a-button>

                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('有效状态',
                      {url:assessCheckApi.modifyHcyState,method:'put',
                      data:{id:ypltHcyFormData['id'],fstate:ypltHcyForm.getFieldValue('fstate')}},
                      'data','fstate','核查员有效状态','ypltHcyForm')">修改有效状态</a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>

            <!-- 药品注册核查员 -->
            <a-collapse-panel
              key="5"
              header="药品注册审评员"
              v-if="ypzcHcyflag"
            >
              <everdayFormNoRowAntcol
                :key="inspectorKey"
                :formItem="ypzcHcyFotItems"
                :beforeCreate="ypzcHcyFot"
                :labelcol="{ span: 8 }"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px" >
                    <a-button
                      @click="saveHcy(ypzcHcyForm, ypzcHcyFormData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                    
                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('所属库',
                      {url:assessCheckApi.modifyHcySsk,method:'put',
                      data:{id:ypzcHcyFormData['id'],fssk:ypzcHcyForm.getFieldValue('fssk')}},
                      'data','fssk','核查员所属库','ypzcHcyForm')">修改所属库</a-button>

                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('有效状态',
                      {url:assessCheckApi.modifyHcyState,method:'put',
                      data:{id:ypzcHcyFormData['id'],fstate:ypzcHcyForm.getFieldValue('fstate')}},
                      'data','fstate','核查员有效状态','ypzcHcyForm')">修改有效状态</a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>

            <!-- 医疗器械核查员 -->
            <a-collapse-panel
              key="6"
              header="医疗器械审评员"
              v-if="ylqxHcyFormData"
            >
              <everdayFormNoRowAntcol
                :key="inspectorKey"
                :formItem="ylqxHcyFotItems"
                :beforeCreate="ylqxHcyFot"
                :labelcol="{ span: 8 }"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(ylqxHcyForm, ylqxHcyFormData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('所属库',
                      {url:assessCheckApi.modifyHcySsk,method:'put',
                      data:{id:ylqxHcyFormData['id'],fssk:ylqxHcyForm.getFieldValue('fssk'),}},
                      'data','fssk','核查员所属库','ylqxHcyForm')">修改所属库</a-button>

                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('有效状态',
                      {url:assessCheckApi.modifyHcyState,method:'put',
                      data:{id:ylqxHcyFormData['id'],fstate:ylqxHcyForm.getFieldValue('fstate'),}},
                      'data','fstate','核查员有效状态','ylqxHcyForm')">修改有效状态</a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>

            <!-- 化妆品核查员 -->
            <a-collapse-panel
              key="7"
              header="化妆品审评员"
              v-if="hzpHcyFormData"
            >
              <everdayFormNoRowAntcol
                :key="inspectorKey"
                :formItem="hzpHcyFotItems"
                :beforeCreate="hzpHcyFot"
                :labelcol="{ span: 8 }"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(hzpHcyForm, hzpHcyFormData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('所属库',
                      {url:assessCheckApi.modifyHcySsk,method:'put',
                      data:{id:hzpHcyFormData['id'],fssk:hzpHcyForm.getFieldValue('fssk'),}},
                      'data','fssk','核查员所属库','hzpHcyForm')">修改所属库</a-button>

                      <a-button 
                      v-if="inspectorId.id"
                      style="margin-left: 15px;" 
                      class="blue-btn" type="primary" 
                      @click="modifyClick('有效状态',
                      {url:assessCheckApi.modifyHcyState,method:'put',
                      data:{id:hzpHcyFormData['id'],fstate:hzpHcyForm.getFieldValue('fstate'),}},
                      'data','fstate','核查员有效状态','hzpHcyForm')">修改有效状态</a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>
          </a-collapse>
        </a-collapse-panel>
        <!-- 审评专家信息 -->
        <a-collapse-panel key="99" header="审评专家信息" :style="customStyle">
          <a-collapse default-active-key="3">
            <!-- 药品生产专家 -->
            <a-collapse-panel key="3" header="药品生产专家" v-if="ypscZjData">
              <everdayFormNoRowAntcol
                :formItem="ypscExpertForItem"
                :beforeCreate="ypscPsyFormFor"
                :labelcol="{ span: 8 }"
                type="ypscZjForm"
                id="ypscZjData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(ypscZjForm, ypscZjData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>
            <!-- 药品流通专家 -->
            <a-collapse-panel key="4" header="药品流通专家" v-if="ypltZjData">
              <everdayFormNoRowAntcol
                :formItem="ypltExpertFotItem"
                :beforeCreate="ypscPsyFormFor"
                :labelcol="{ span: 8 }"
                type="ypltZjForm"
                id="ypltZjData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(ypltZjForm, ypltZjData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>

            <!-- 药品注册专家 -->
            <a-collapse-panel key="5" header="药品注册专家" v-if="ypzcZjData">
              <everdayFormNoRowAntcol
                :formItem="ypzcExpertFotItem"
                :beforeCreate="ypscPsyFormFor"
                :labelcol="{ span: 8 }"
                type="ypzcZjForm"
                id="ypzcZjData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(ypzcZjForm, ypzcZjData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>

            <!-- 医疗器械专家 -->
            <a-collapse-panel key="6" header="医疗器械专家" v-if="ylqxZjData">
              <everdayFormNoRowAntcol
                :formItem="ylqxExpertFotItem"
                :beforeCreate="ypscPsyFormFor"
                :labelcol="{ span: 8 }"
                type="ylqxZjForm"
                id="ylqxZjData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(ylqxZjForm, ylqxZjData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>

            <!-- 化妆品专家 -->
            <a-collapse-panel key="7" header="化妆品专家" v-if="hzpZjData">
              <everdayFormNoRowAntcol
                :formItem="hzpExpertFotItem"
                :beforeCreate="ypscPsyFormFor"
                :labelcol="{ span: 8 }"
                type="hzpZjForm"
                id="hzpZjData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(hzpZjForm, hzpZjData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>
          </a-collapse>
        </a-collapse-panel>
        <!-- 评审员信息 -->
        <a-collapse-panel key="199" header="评审员信息" :style="customStyle">
          <!-- 药品生产评审员信息 -->
          <a-collapse default-active-key="3">
            <a-collapse-panel
              key="3"
              header="药品生产评审员"
              v-if="ypscPsyData"
            >
              <everdayFormNoRowAntcol
                :formItem="ypscExpertForItem"
                :beforeCreate="ypscPsyFormFor"
                :labelcol="{ span: 8 }"
                type="ypscPsyForm"
                id="ypscPsyData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(ypscPsyForm, ypscPsyData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>
            <!-- 药品流通评审员 -->
            <a-collapse-panel
              key="4"
              header="药品流通评审员"
              v-if="ypltPsyData"
            >
              <everdayFormNoRowAntcol
                :formItem="ypltExpertFotItem"
                :beforeCreate="ypltHcyFor"
                :labelcol="{ span: 8 }"
                type="ypltPsyForm"
                id="ypltPsyData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(ypltPsyForm, ypltPsyData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>

            <!-- 药品注册评审员 -->
            <a-collapse-panel
              key="5"
              header="药品注册评审员"
              v-if="ypzcPsyData"
            >
              <everdayFormNoRowAntcol
                :formItem="ypzcExpertFotItem"
                :beforeCreate="ypzcHcyFot"
                :labelcol="{ span: 8 }"
                type="ypzcPsyForm"
                id="ypzcPsyData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(ypzcPsyForm, ypzcPsyData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>

            <!-- 医疗器械评审员 -->
            <a-collapse-panel
              key="6"
              header="医疗器械评审员"
              v-if="ylqxPsyData"
            >
              <everdayFormNoRowAntcol
                :formItem="ylqxExpertFotItem"
                :beforeCreate="ylqxHcyFot"
                :labelcol="{ span: 8 }"
                type="ylqxPsyForm"
                id="ylqxPsyData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(ylqxPsyForm, ylqxPsyData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>

            <!-- 化妆品评审员 -->
            <a-collapse-panel key="7" header="化妆品评审员" v-if="hzpPsyData">
              <everdayFormNoRowAntcol
                :formItem="hzpExpertFotItem"
                :beforeCreate="hzpHcyFot"
                :labelcol="{ span: 8 }"
                type="hzpPsyForm"
                id="hzpPsyData"
              >
                <template #save>
                  <div style="margin-top: 20px;margin-left: 120px">
                    <a-button
                      @click="saveHcy(hzpPsyForm, hzpPsyData)"
                      type="primary"
                      class="blue-btn"
                    >
                      保存
                    </a-button>
                  </div>
                </template>
              </everdayFormNoRowAntcol>
            </a-collapse-panel>
          </a-collapse>
        </a-collapse-panel>
        <a-collapse-panel key="35" header="选派记录" :style="customStyle">
          <div>
            <com-vxe-table
              :columns="queryMyXpjlColumns"
              :axios="queryMyXpjlPage"
              :initialize="inspectorId"
              row-id="id"
              :from-item="queryMyXpjlFromItem"
              height="300"
            >
            </com-vxe-table>
          </div>
        </a-collapse-panel>

        <a-collapse-panel key="45" header="审评信息" :style="customStyle">
          <div>
            <com-vxe-table
              :columns="queryMyXpjljcColumns"
              :axios="queryMyXpjlPage"
              :initialize="inspectorId"
              row-id="id"
              :from-item="queryMyXpjlFromItem"
              height="300"
            >
            </com-vxe-table>
          </div>
        </a-collapse-panel>

        <a-collapse-panel key="46" header="调派信息" :style="customStyle">
          <div>
            <com-vxe-table
              :columns="queryMyDpxxColumns"
              :axios="queryMyDpxxPage"
              :initialize="inspectorId"
              row-id="id"
              :from-item="queryMyXpjlFromItem"
              height="300"
            >
            </com-vxe-table>
          </div>
        </a-collapse-panel>

        <a-collapse-panel key="47" header="考核信息" :style="customStyle">
          <div>
            <com-vxe-table
              :columns="queryMyKhxxColumns"
              :axios="queryMyKhxxPage"
              :initialize="inspectorId"
              row-id="id"
              :from-item="queryMyXpjlFromItem"
              height="300"
            >
            </com-vxe-table>
          </div>
        </a-collapse-panel>

        <a-collapse-panel key="48" header="培训记录" :style="customStyle">
          <div>
            <com-vxe-table
              :columns="sysQueryPageListColumns"
              :axios="sysQueryPageListPage"
              row-id="id"
              :from-item="queryMyXpjlFromItem"
              :config="config"
              :initialize="inspectorId"
              @vadd-ok="handleAdd"
              @add-open="handleaddOpen"
              vId="培训记录"
              @com-edit="handlerQueryById"
              @com-delete="handlerDelete"
              ref="comTable"
              height="300"
            >
              <template #update="data">
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickDownloadFile('培训记录', data.refresh)"
                  ><a-icon type="download" class="m10" />导出</vxe-button
                >
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickDownloadFile('培训记录模板', data.refresh)"
                  ><a-icon type="download" class="m10" />导出模板</vxe-button
                >
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickUpdateFile('培训记录', data.refresh)"
                  ><a-icon type="import" class="m10" />导入</vxe-button
                >
              </template>
            </com-vxe-table>
          </div>
        </a-collapse-panel>

        <a-collapse-panel key="49" header="工作经历" :style="customStyle">
          <div>
            <com-vxe-table
              :columns="GzQueryPageListColumns"
              :axios="GzQueryPageListPage"
              row-id="id"
              :from-item="queryMyXpjlFromItem"
              vId="工作经历"
              :config="config"
              :initialize="inspectorId"
              @vadd-ok="handleAdd"
              @add-open="handleaddOpen"
              @com-edit="handlerQueryById"
              @com-delete="handlerDelete"
              ref="comTable"
              height="300"
            >
              <template #update="data">
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickDownloadFile('工作经历', data.refresh)"
                  ><a-icon type="download" class="m10" />导出</vxe-button
                >
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickDownloadFile('工作经历模板', data.refresh)"
                  ><a-icon type="download" class="m10" />导出模板</vxe-button
                >
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickUpdateFile('工作经历', data.refresh)"
                  ><a-icon type="import" class="m10" />导入</vxe-button
                >
              </template>
            </com-vxe-table>
          </div>
        </a-collapse-panel>

        <a-collapse-panel key="50" header="教育经历" :style="customStyle">
          <div>
            <com-vxe-table
              :columns="JyQueryPageListColumns"
              :axios="JyQueryPageListPage"
              row-id="id"
              :from-item="queryMyXpjlFromItem"
              vId="教育经历"
              :config="config"
              :initialize="inspectorId"
              @vadd-ok="handleAdd"
              @add-open="handleaddOpen"
              @com-edit="handlerQueryById"
              @com-delete="handlerDelete"
              ref="comTable"
              height="300"
            >
              <template #update="data">
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickDownloadFile('教育经历', data.refresh)"
                  ><a-icon type="download" class="m10" />导出</vxe-button
                >
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickDownloadFile('教育经历模板', data.refresh)"
                  ><a-icon type="download" class="m10" />导出模板</vxe-button
                >
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickUpdateFile('教育经历', data.refresh)"
                  ><a-icon type="import" class="m10" />导入</vxe-button
                >
              </template>
            </com-vxe-table>
          </div>
        </a-collapse-panel>

        <a-collapse-panel key="53" header="奖惩情况" :style="customStyle">
          <div>
            <com-vxe-table
              v-if="inspectorId.id"
              :columns="JcQkqueryColumns"
              :axios="JcQkqueryPageListPage"
              row-id="id"
              :from-item="queryMyXpjlFromItem"
              vId="奖惩情况"
              :config="config"
              :initialize="inspectorId"
              @vadd-ok="handleAdd"
              @add-open="handleaddOpen"
              @com-edit="handlerQueryById"
              @com-delete="handlerDelete"
              ref="comTable"
              height="300"
            >
              <template #update="data">
                <!-- <vxe-button
                  
                  class-name="btn_bgc"
                  @click="clickDownloadFile('奖惩情况', data.refresh)"
                  ><a-icon type="download" class="m10" />导出</vxe-button
                >
                <vxe-button
                v-if="inspectorId.id"
                  class-name="btn_bgc"
                  @click="clickDownloadFile('奖惩情况模板', data.refresh)"
                  ><a-icon type="download" class="m10" />导出模板</vxe-button
                > -->
                <!-- <vxe-button
                v-if="inspectorId.id"
                  class-name="btn_bgc"
                  @click="clickUpdateFile('奖惩情况', data.refresh)"
                  ><a-icon type="import" class="m10" />导入</vxe-button
                > -->
              </template>
            </com-vxe-table>
            <com-vxe-table
              v-else
              :columns="JcQkqueryColumnsOwn"
              :axios="JcQkqueryPageListPage"
              row-id="id"
              :from-item="queryMyXpjlFromItem"
              vId="奖惩情况"
              :config="config"
              :initialize="inspectorId"
              ref="comTable"
              height="300"
            >
              <template #update="data">
                <vxe-button
                  class-name="btn_bgc"
                  @click="clickDownloadFile('奖惩情况', data.refresh)"
                  ><a-icon type="download" class="m10" />导出</vxe-button
                >
              </template>
            </com-vxe-table>
          </div>
        </a-collapse-panel>
      </a-collapse>
    </div>
    <vxe-modal
      v-model="vxModal.visabled"
      :width="vxModal.width"
      :height="vxModal.height"
      :title="vxModal.title"
      show-footer
      @confirm="handlerEdit"
    >
      <template #default>
        <div>
          <everdayFormNoRowAntcol
            v-if="vxModal.id === '培训记录'"
            ref="editform"
            :labelcol="{ span: 8 }"
            :form-item="sysQueryForm"
          >
          </everdayFormNoRowAntcol>
          <a-form v-if="vxModal.id === '培训记录'" layout="inline" style="display: flex;justify-content: flex-start;">
            <a-form-item class="vxe-table-box-w" >
                <a-upload style="display: inline-block;" :beforeUpload="segmentBeforeUpload" action="" @change="uploadClick">
                    <a-button class="blue-btn" type="primary">上传文件</a-button>
                </a-upload>
            </a-form-item>
          </a-form>
          <a-list v-if="vxModal.id === '培训记录'" item-layout="horizontal" :data-source="filesListData">
            <a-list-item slot="renderItem" slot-scope="item, index">
              <a-list-item-meta>
                <a slot="title" href="#">{{ item.fwjxsmc + item.fwjlx }}</a>
              </a-list-item-meta>
              <a-button style="margin-right: 10px;" class="blue-btn" type="primary" @click="downloadFiles(item)" >下载培训记录文件</a-button>
              <a-button class="red-btn" type="primary" @click="ddeleteFiles(item.id)" >删除培训记录文件</a-button>
            </a-list-item>
          </a-list>
          <everdayFormNoRowAntcol
            v-if="vxModal.id === '工作经历'"
            ref="editform"
            :labelcol="{ span: 8 }"
            :form-item="GzQueryForm"
          >
          </everdayFormNoRowAntcol>
          <everdayFormNoRowAntcol
            v-if="vxModal.id === '教育经历'"
            ref="editform"
            :labelcol="{ span: 8 }"
            :form-item="JyQueryForm"
          >
          </everdayFormNoRowAntcol>
          <everdayFormNoRowAntcol
            v-if="vxModal.id === '奖惩情况'"
            formLayout="horizontal"
            ref="editform"
            :labelcol="{ span: 8 }"
            :form-item="sysUserJlcfqkForm"
          >
          </everdayFormNoRowAntcol>
        </div>
      </template>
    </vxe-modal>
    <a-modal 
    v-model:visible="separateVisible" 
    :title="'修改'+editInterfaceInfo.title" 
    @ok="separateHandleOk" 
    @cancel="separateHandleCancel">
      <a-form
        layout="inline" 
        :label-col="{ span: 8 }" 
        :wrapper-col="{ span: 12 }">
          <a-form-item label="账号" v-if="editInterfaceInfo.title == '账号'">
              <a-input
              :placeholder="'请输入'+editInterfaceInfo.title"
              v-model="editInterfaceInfo.data[editInterfaceInfo.key][editInterfaceInfo.dataKey]"
              />
          </a-form-item>
          <a-form-item :label="editInterfaceInfo.title" v-if="editInterfaceInfo.title && editInterfaceInfo.title !== '账号'">
            <compSelector
            :key="separateKey"
            v-model="editInterfaceInfo.data[editInterfaceInfo.key][editInterfaceInfo.dataKey]" 
            compType="Select"
            :defaultValue="editInterfaceInfo.data[editInterfaceInfo.key][editInterfaceInfo.dataKey]"
            :dictionaryType="editInterfaceInfo.dictionaryType"
            :width="150"
            />
        </a-form-item>
      </a-form>
    </a-modal>
  </a-spin>
</template>
<script>
import VXETable from "vxe-table";
import everdayFormNoRowAntcol from "../components/everday-form-noRowAntcol.vue";
import {
  exportUserJlcfqkData,
  exportUserJlcfqkDataFile,
  sysUserJlcfqkAdd,
  exportUserJlcfqkQueryById,
  sysUsereditJcqk,
  sysUserDeleteBatchJcqk,
  queryMyJbxx,
  updateUser,
  updateHcy,
  queryMyXpjl,
  queryMyKhxx,
  queryMyDpxx,
  sysQueryPageList,
  sysAddPxjl,
  sysDeleteBatch,
  sysQueryById,
  sysEditPxjl,
  GzAddPxjl,
  GzQueryPageList,
  GzQueryById,
  GzEditPxjl,
  GzDeleteBatch,
  JyQueryPageList,
  JyDeleteBatch,
  JyAddPxjl,
  JyEditPxjl,
  JyQueryById,
  JcQkqueryPageList,
  sysImpPxjlData,
  GzImpPxjlData,
  JyImpPxjlData,
  sysDownUserPxjlTemplate,
  sysExportUserPxjlData,
  GzDownUserPxjlTemplate,
  GzExportUserPxjlData,
  JyDownUserPxjlTemplate,
  JyExportUserPxjlData,
  userSignatureDownload,
  userSignatureImport,
  modifyServe,
  queryPxjlFileList,
  uploadPxjlFile,
  deletePxjlFileById,
  getPxjlFile
} from "../api/inspector";
import comVxeTable from "@/views/everydayCheck/components/vxe-table/com-vxe-table";
import { dict } from "../api/common";
import assessCheckApi from '../../assessCheck/inspectorLibrary/service/api'
import validator from '@/common/validator'
import compSelector from '@/components/compSelector/compSelector'
import blobType from '@/common/blobType'
// 用户
const userMessageForItem = [
{
    type: "input",
    label: "登录账号",
    model: "username",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "真实姓名",
    model: "realname",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "手机号码",
    model: "phone",
    rules:[{
        required: true,
        message: '请输入手机号码',
        trigger: 'blur',
    },{
        pattern: validator.isPhone.reg,
        message: '请输入正确的手机号码',
        trigger: 'blur',
    }],
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    label: "性别",
    model: "sex",
    compType:'Radio',
    width:150,
    span: 8,
    dictType: "sex",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "电子邮箱",
    model: "email",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    dictType: "gcyssds001",
    label: "所属区域",
    width:150,
    model: "fssqy",
    compType:'Select',
    span: 8,
    labelCol: { span: 8 },
  },
  {
    label: "民族",
    model: "fmz",
    span: 8,
    dictType: "mz001",
    compType:'Select',
    type: "comp-selector-type",
    width:150,
    labelCol: { span: 8 },
  },
  {
    dictType: "zzmm001",
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "政治面貌",
    model: "fzzmm",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    dictType: "sfyjsry001",
    label: "是否药检所人员",
    compType:'Radio',
    model: "fsfyjsry",
    // disabled:true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input-password",
    label: "身份证号",
    className:'form-item-box-witdh-l',
    model: "fsfzh",
    span: 8,
    dictType: "yhxb001",
    rules:[{
        required: true,
        message: '请输入身份证号',
        trigger: 'blur',
    },{
        pattern: validator.isIdCard.reg,
        message: '请输入正确的身份证号',
        trigger: 'blur',
    }],
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "聘用文件号",
    model: "fpywjh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "line",
    span: 24,
  },
  //工作信息
  {
    type: "input",
    label: "从事工作",
    model: "fcsgz",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    dictType: "hcygzzt001",
    label: "执勤状态",
    disabled: true,
    model: "fgzzt",
    compType:'Select',
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "工作单位",
    className:'form-item-box-witdh-l',
    model: "fgzdw",
    rules:[{
        required: true,
        message: '请输入单位名称',
        trigger: 'blur',
    }],
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "工作单位地址",
    className:'form-item-box-witdh-l',
    model: "fgzdwdz",
    span: 16,
    labelCol: { span: 4 },
  },
  {
    type: "input",
    label: "职务",
    model: "fzw",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    dictType: "zc001",
    label: "职称",
    model: "fzc",
    span: 8,
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "dwlx001",
    label: "单位类型",
    model: "fdwlx",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "单位电话",
    model: "fdwdh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "单位邮箱",
    model: "fdwyx",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "line",
    span: 24,
  },
  //教育信息
  {
    type: "comp-selector-type",
    width:150,
    dictType: "xldm001",
    label: "学历",
    model: "fxl",
    compType:'Select',
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "毕业院校",
    className:'form-item-box-witdh-l',
    model: "fbyyx",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "所学专业",
    model: "fsxzy",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "line",
    span: 24,
  },
  //收款信息
  {
    type: "input-password",
    label: "银行卡号",
    model: "fyhkh",
    className:'form-item-box-witdh-l',
    span: 8,
    slot: "fyhkh",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "开户行所在地",
    className:'form-item-box-witdh-l',
    model: "fkhhszd",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    dictType: "xdyx001",
    label: "开户行",
    compType:'Select',
    model: "fkfh",
    span: 8,
    labelCol: { span: 8 },
    slot: "xdyx001",
  },
  
  
]

// ---------审评员信息---------
// 药品生产审评员001002
const ypscHcyForItems = [
  {
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    dictType: "zytc001002",
    label: "专业特长",
    className:'row-w100',
    model: "fszly",
    span: 16,
    option: [],
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
   {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];
// 药品流通审评员001003
const ypltHcyFotItems = [
  {
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    dictType: "zytc001003",
    label: "专业特长",
    model: "fszly",
    span: 16,
    option: [],
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
   {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];

// 药品注册核查员001001
const ypzcHcyFotItems = [
{
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    dictType: "zytc001001",
    label: "专业特长",
    model: "fszly",
    span: 16,
    option: [],
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
   {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];

// 医疗器械核查员002
const ylqxHcyFotItems = [
{
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    dictType: "zytc002",
    label: "专业特长",
    model: "fszly",
    span: 16,
    option: [],
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
   {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];

// 化妆品核查员003
const hzpHcyFotItems = [
{
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    dictType: "zytc003",
    label: "专业特长",
    model: "fszly",
    span: 16,
    option: [],
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
   {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];


// -------审评专家信息----
// 药品生产审评员001002
const ypscExpertForItem = [
  {
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    dictType: "zytc001002",
    label: "专业特长",
    model: "fszly",
    span: 16,
    option: [],
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
   {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];
// 药品流通审评员001003
const ypltExpertFotItem = [
{
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    dictType: "zytc001002",
    label: "专业特长",
    model: "fszly",
    span: 16,
    option: [],
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
   {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];

// 药品注册核查员001001
const ypzcExpertFotItem = [
  {
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    label: "专业特长",
    model: "fszly",
    span: 16,
    dictType: "zytc001001",
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  //   labelCol: { span: 8 },
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
   {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];

// 医疗器械核查员002
const ylqxExpertFotItem = [
  {
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    label: "专业特长",
    model: "fszly",
    span: 16,
    dictType: "zytc002",
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  //   labelCol: { span: 8 },
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
   {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];

// 化妆品核查员003
const hzpExpertFotItem = [
  {
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    label: "专业特长",
    model: "fszly",
    span: 16,
    dictType: "zytc003",
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  //   labelCol: { span: 8 },
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "jcyjzqk001",
    label: "兼职情况",
    model: "fjzqk",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "tjhcyzglx001",
    label: "审评员资格",
    model: "fjcyzg",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "ssjcjg001",
    label: "所属审评机构",
    model: "fssjcjg",
    span: 8,
    labelCol: { span: 8 },
  },
];


// 培训表单
const sysQueryForm = [
  {
    type: "input",
    label: "姓名",
    model: "fusermc",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    label: "参加方式",
    model: "fcjfs",
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "cjpxfs001",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    label: "培训类型",
    model: "fpxlx",
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "pxlx001",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "培训开始时间",
    model: "fpxkssj",
    format: "YYYY-MM-DD",
    span: 8,
    labelCol: { span: 9 },
  },
  {
    type: "datetime",
    label: "培训结束时间",
    model: "fpxjssj",
    format: "YYYY-MM-DD",
    span: 8,
    labelCol: { span: 9 },
  },
  {
    type: "input",
    label: "培训名称",
    model: "fpxmc",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "培训内容",
    model: "fpxnr",
    span: 16,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "组织单位",
    model: "fzzdw",
    span: 16,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "培训主讲人",
    model: "fpxzjr",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "培训地点",
    model: "fpxdd",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "pxdj001",
    label: "培训等级",
    model: "fpxdj",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "number",
    label: "培训学时",
    model: "fpxxs",
    span: 8,
    labelCol: { span: 8 },
  },
];

// 工作经历
const GzQueryForm = [
  {
    type: "input",
    label: "姓名",
    model: "fusermc",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "工作单位",
    model: "fgzdw",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "工作开始时间",
    model: "fgzkssj",
    format: "YYYY-MM-DD",
    span: 8,
    labelCol: { span: 9 },
  },
  {
    type: "datetime",
    label: "工作结束时间",
    model: "fgzjssj",
    format: "YYYY-MM-DD",
    span: 8,
    labelCol: { span: 9 },
  },
  {
    type: "input",
    label: "工作部门",
    model: "fgzbm",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "从事工作",
    model: "fcsgz",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "职务",
    model: "fzw",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "职称",
    model: "fzc",
    span: 8,
    labelCol: { span: 8 },
  },
];

// 教育经历
const JyQueryForm = [
  {
    type: "input",
    label: "姓名",
    model: "fusermc",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "毕业院校",
    model: "fbyyx",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "专业",
    model: "fzy",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "系别",
    model: "fzy",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "xwdm001",
    label: "学位",
    model: "fxw",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "xldm001",
    label: "学历",
    model: "fxl",
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "开始时间",
    model: "fkssj",
    format: "YYYY-MM-DD",
    span: 8,
    labelCol: { span: 9 },
  },
  {
    type: "datetime",
    label: "结束时间",
    model: "fjssj",
    format: "YYYY-MM-DD",
    span: 8,
    labelCol: { span: 9 },
  },
];

// 奖惩情况
const sysUserJlcfqkForm = [
  {
    type: "input",
    label: "姓名",
    model: "fusermc",
    span: 12,
    labelCol: { span: 4 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   span: 12,
  //   labelCol: { span: 4 },
  // },
  {
    type: "input",
    label: "名称",
    model: "fmc",
    span: 12,
    labelCol: { span: 4 },
  },
  {
    type: "datetime",
    label: "时间",
    model: "fsj",
    format: "YYYY-MM-DD",
    span: 12,
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "类型",
    disabled: true,
    model: "flx",
    span: 8,
    dictType: "jlcfqklx001",
    labelCol: { span: 8 },
  },
  {
    type: "textarea",
    label: "背景原因",
    model: "fb",
    span: 24,
    labelCol: { span: 2 },
  },
  {
    type: "textarea",
    label: "备注",
    model: "fbz",
    span: 24,
    labelCol: { span: 2 },
  },
];

// 评审员
// 医疗器械核查员
const ypscPsyFormItem = [
  {
    type: "comp-selector-type",
    width:150,
    compType:'Checkbox',
    className:'row-w100',
    label: "专业特长",
    model: "fszly",
    span: 16,
    dictType: "zytc002",
    labelCol: { span: 4 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "有效状态",
    disabled: true,
    model: "fstate",
    span: 8,
    dictType: "hcyyxzt001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    label: "序列类型",
    model: "fxllx",
    disabled: true,
    span: 8,
    dictType: "jcyxllx001",
    labelCol: { span: 8 },
  },
  {
    type: "comp-selector-type",
    width:150,
    compType:'Select',
    dictType: "hcydj001",
    label: "等级",
    model: "flevel",
    span: 8,
    labelCol: { span: 8 },
  },
  // {
  //   type: "input",
  //   label: "类型",
  //   model: "flx",
  //   disabled: true,
  //   span: 8,
  //   labelCol: { span: 8 },
  // },
  {
    type: "input",
    label: "所属库",
    model: "fssk",
    disabled: true,
    span: 8,
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘开始时间",
    model: "fspsj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "datetime",
    label: "受聘结束时间",
    model: "fspjssj",
    span: 8,
    format: "YYYY-MM-DD",
    labelCol: { span: 8 },
  },
  {
    type: "input",
    label: "证书编号",
    model: "fzsbh",
    span: 8,
    labelCol: { span: 8 },
  },
];
const filesListData = []
export default {
  components: { everdayFormNoRowAntcol, comVxeTable,  compSelector },
  name: "insp-user-message",
  props:{
    inspectorId:{
      type:Object,
      default:{id:'',fuserid:''},
      required:false,
      // id:'',
        // fuserid:'',
    }
  },
  watch:{
    inspectorId:{
      handler(newval,oldVal){
        this.$nextTick(()=>{
          this.inspectorId = newval
        })
      },
      deep:true,
    }
  },
  data() {
    return {
      inspectorKey:null,
      inspectorId:this.inspectorId,
      assessCheckApi:assessCheckApi,
      editInterfaceInfo:{
        title:'',
        data:{
            data:{
                id:'' 
            }
        },
        key:'data',
        dataKey:'id',
        dictionaryType:''
      },
      separateVisible:false,
      separateKey:null,



      showNameIs: false,
      showNameIs2: false,
      // 用户
      userMessageForItem,
      form: null,
      formData: {},
      // 保存当前用户的id
      userId: "",
      // 审查生产核查员
      ypscExpertForItem,
      ypscHcyform: null,
      ypscHcyformData: null,

      // 药品流通核查员
      ypltExpertFotItem,
      ypltHcyForm: {},
      ypltHcyFormData: null,

      // 药品注册核查员
      ypzcExpertFotItem,
      ypzcHcyForm: {},
      ypzcHcyFormData: null,

      // 医疗器械核查员
      ylqxExpertFotItem,
      ylqxHcyForm: {},
      ylqxHcyFormData: null,

      // 化妆品核查员
      hzpExpertFotItem,
      hzpHcyForm: {},
      hzpHcyFormData: null,

      // 选派记录
      queryMyXpjlPage: queryMyXpjl,
      queryMyXpjlColumns: [
        {
          type: "seq",
          title: "序号",
          width: "60",
        },
        {
          title: "审评员姓名",
          field: "fjcyxm",
        },
        {
          title: "选派类型",
          field: "fxplx",
        },
        {
          title: "任务类型",
          width: "60",
          field: "frwlx",
        },
        {
          title: "指派人名称",
          field: "fzprmc",
        },
        {
          title: "审评开始时间",
          field: "fcykssj",
        },
        {
          title: "审评结束时间",
          field: "fcyjssj",
        },
        {
          title: "指派时间",
          field: "fzpsj",
        },
        {
          title: "是否组长",
          field: "fssk",
        },
        {
          title: "选派方式",
          field: "fxpfs",
        },
        {
          title: "所属审评机构",
          field: "fssjcjg",
        },
        {
          title: "是否同意选派",
          field: "fsftyxp",
        },
        {
          title: "原因说明",
          field: "fbtyyy",
        },
      ],
      queryMyXpjlFromItem: [
        {
          field: "year",
          title: "年份",
          type: "input",
        },
      ],
      // 审评信息
      queryMyXpjljcColumns: [
        {
          type: "seq",
          title: "序号",
          width: "60",
        },
        {
          title: "审评员姓名",
          field: "fjcyxm",
        },
        {
          title: "任务类型",
          width: "60",
          field: "frwlx",
        },
        {
          title: "被审评单位",
          field: "fqymc",
        },
        {
          title: "审评开始时间",
          field: "fcykssj",
        },
        {
          title: "审评结束时间",
          field: "fcyjssj",
        },
        {
          title: "审评范围",
          field: "fcyjcfw",
        },
        {
          title: "是否组长",
          field: "fssk",
        },
        {
          title: "日常考核",
          field: "frckpjg",
        },
        {
          title: "所属审评机构",
          field: "fssjcjg",
        },
        {
          title: "操作",
          field: "operate",
          width: "180",
          content:'查看'
        },
      ],
      // 调派信息
      queryMyDpxxPage: queryMyDpxx,
      queryMyDpxxColumns: [
        {
          type: "seq",
          title: "序号",
          width: "60",
        },
        {
          title: "姓名",
          field: "fjcyxm",
        },
        {
          title: "调派次数",
          width: "60",
          field: "dpcs",
        },
        {
          title: "接受调派次数",
          field: "jsdpcs",
        },
        {
          title: "未接受调派次数",
          field: "wjsdpcs",
        },
        {
          title: "总调派次数",
          field: "totaldpcs",
        },
        {
          title: "总接受调派次数",
          field: "totaljsdpcs",
        },
        {
          title: "总未接受调派次数",
          field: "totalwjsdpcs",
        },
        {
          title: "所属审评机构",
          field: "fssjcjg",
        },
      ],

      // 考核信息
      queryMyKhxxPage: queryMyKhxx,
      queryMyKhxxColumns: [
        {
          type: "seq",
          title: "序号",
          width: "60",
        },
        {
          title: "姓名",
          field: "fjcyxm",
        },
        {
          title: "考核类型",
          width: "60",
          field: "fkhlx",
        },
        {
          title: "考核时间",
          field: "fkhsj",
        },
        {
          title: "考核结果",
          field: "fkhjg",
        },
        {
          title: "相关说明",
          field: "fbz",
        },
        {
          title: "所属审评机构",
          field: "fssjcjg",
        },
      ],
      // 培训记录
      sysQueryPageListPage: sysQueryPageList,
      sysQueryPageListColumns: [
        {
          type: "seq",
          title: "序号",
          width: "60",
        },
        {
          title: "姓名",
          field: "fusermc",
        },
        {
          title: "参加方式",
          field: "fcjfs",
        },
        {
          title: "培训类型",
          width: "60",
          field: "fpxlx",
        },
        {
          title: "培训开始时间",
          field: "fpxkssj",
        },
        {
          title: "培训结束时间",
          field: "fpxjssj",
        },
        {
          title: "培训名称",
          field: "fpxmc",
        },
        {
          title: "培训主讲人",
          field: "fpxzjr",
        },
        {
          title: "培训地点",
          field: "fpxdd",
        },
        {
          title: "培训等级",
          field: "fpxdj",
        },
        {
          title: "培训学时",
          field: "fpxxs",
        },
        {
          title: "操作",
          field: "operate",
          width: "200",
          flag: true,
          render(h, param) {
            const delbtn = h(
              "button",
              {
                class: "",
                style: "",
                on: {
                  click: () => {
                    // //console.log("点击删除" + param.row.name, that.windowName);
                    //console.log("点击", param); // = {"row": {"name": "王小虎","age": 18},"index": 0}
                  },
                },
              },
              "删除"
            );
            return h("div", [delbtn]);
          },
        },
      ],
      sysQueryForm,

      // 工作记录
      GzQueryPageListPage: GzQueryPageList,
      GzQueryPageListColumns: [
        {
          type: "seq",
          title: "序号",
          width: "60",
        },
        {
          title: "姓名",
          field: "fusermc",
        },
        {
          title: "工作单位",
          field: "fgzdw",
        },
        {
          title: "工作开始时间",
          field: "fgzkssj",
        },
        {
          title: "工作结束时间",
          field: "fgzjssj",
        },
        {
          title: "工作部门",
          field: "fgzbm",
        },
        {
          title: "从事工作",
          field: "fcsgz",
        },
        {
          title: "职务",
          field: "fzw",
        },
        {
          title: "职称",
          field: "fzc",
        },
        {
          title: "操作",
          field: "operate",
          width: "200",
          flag: true,
        },
      ],
      GzQueryForm,

      // 教育记录
      JyQueryPageListPage: JyQueryPageList,
      JyQueryPageListColumns: [
        {
          type: "seq",
          title: "序号",
          width: "60",
        },
        {
          title: "姓名",
          field: "fusermc",
        },
        {
          title: "毕业院校",
          field: "fbyyx",
        },
        {
          title: "专业",
          field: "fzy",
        },
        {
          title: "系别",
          field: "fxb",
        },
        {
          title: "学位",
          field: "fxw",
        },
        {
          title: "学历",
          field: "fxl",
        },
        {
          title: "开始时间",
          field: "fkssj",
        },
        {
          title: "结束时间",
          field: "fjssj",
        },
        {
          title: "操作",
          field: "operate",
          width: "200",
          flag: true,
        },
      ],
      JyQueryForm,

      // 奖惩清空
      JcQkqueryPageListPage: JcQkqueryPageList,
      JcQkqueryColumns: [
        {
          type: "seq",
          title: "序号",
          width: "60",
        },
        {
          title: "姓名",
          field: "fusermc",
        },
        {
          title: "类型",
          field: "flx",
        },
        {
          title: "名称",
          field: "fmc",
        },
        {
          title: "背景原因",
          field: "fb",
        },
        {
          title: "时间",
          field: "fsj",
        },
        {
          title: "备注",
          field: "fbz",
        }
      ],
      JcQkqueryColumnsOwn: [
        {
          type: "seq",
          title: "序号",
          width: "60",
        },
        {
          title: "姓名",
          field: "fusermc",
        },
        {
          title: "类型",
          field: "flx",
        },
        {
          title: "名称",
          field: "fmc",
        },
        {
          title: "背景原因",
          field: "fb",
        },
        {
          title: "时间",
          field: "fsj",
        },
        {
          title: "备注",
          field: "fbz",
        },
        {
          title: "操作",
          field: "operate",
          width: "200",
          flag: true,
        },
      ],
      sysUserJlcfqkForm,
      // 表格配置对象
      config: {
        toobar: {
          class: "btn_bgc",
          add: true,
          modal: true,
          modalConfig: {
            visabled: false,
            width: "65vw",
            height: "70vh",
            title: "",
            content: "",
          },
          formItem: [],
          btn: true,
          button: {
            // 上传
            update: {
              render(h, param) {},
            },
          },
        },
        table: {
          // 操作栏配置项
          operate: {
            flag: true,
            html: "button",
            template: {
              class: "",
              style: "",
              on: {
                click: ($event, row) => {
                  //console.log("点击", row); // = {"row": {"name": "王小虎","age": 18},"index": 0} }
                },
              },
            },
          },
        },
      },
      customStyle:
        "background: #f7f7f7;border-radius: 4px;margin-bottom: 10px;border: 0;overflow: hidden",
      spinning: false,

      // 富文本框
      vxModal: {
        visabled: false,
        width: "65vw",
        height: "70vh",
        title: "",
        content: "",
        id: "",
      },
      // 需要提交或者编辑得表单id
      fid: "",
      timeout: [],

      // 评审员
      // 药品生产
      ypscPsyForm: {},
      ypscPsyData: null,
      ypscPsyFormItem,
      //药品流通
      ypltPsyForm: {},
      ypltPsyData: null,
      // 药品注册
      ypzcPsyForm: {},
      ypzcPsyData: {},
      // 医疗机械
      ylqxPsyData: null,
      ylqxPsyForm: {},
      // 化妆品
      hzpPsyData: null,
      hzpPsyForm: {},

      // 专家
      // 化妆品
      hzpZjData: null,
      hzpZjForm: {},
      // 医疗机械
      ylqxZjData: null,
      ylqxZjForm: {},
      // 药品流通
      ypltZjData: null,
      ypltZjForm: {},
      // 药品生产
      ypscZjData: null,
      ypscZjForm: {},
      // 药品注册
      ypzcZjData: null,
      ypzcZjForm: {},
      ypscHcyForItems,
      ypltHcyFotItems,
      ypzcHcyFotItems,
      ylqxHcyFotItems,
      hzpHcyFotItems,

      //
      uploadPxjlFileid: '',
      filesListData,
      blobType:blobType,
    };
  },
  computed: {
    ypzcHcyflag() {
      return this.ypzcHcyFormData ? true : false;
    },
  },
  created() {
    // this.dictType()
    // this.inspectorMessage();
  },
  methods: {
    // 用户
    everdayform(form) {
      this.form = form;
      this.inspectorMessage();
      // const res = this.dictType();
      // //console.log(res);
    },
    // 生产核查员
    ypscHcyFor(form) {
      //console.log('这个是什么东西',form)
      this.ypscHcyform = form;
      this.ypscHcyform.setFieldsValue(
        this.lodash.pick(
          this.ypscHcyformData,
          Object.keys(this.ypscHcyformData)
        )
      );
    },
    // 药品流通核查员
    ypltHcyFor(form) {
      this.ypltHcyForm = form;
      this.ypltHcyForm.setFieldsValue(
        this.lodash.pick(
          this.ypltHcyFormData,
          Object.keys(this.ypltHcyFormData)
        )
      );
    },
    // 药品注册核查员
    ypzcHcyFot(form) {
      this.ypzcHcyForm = form;
      this.ypzcHcyFormData = this.ypzcHcyFormData || {};
      this.ypzcHcyForm.setFieldsValue(
        this.lodash.pick(
          this.ypzcHcyFormData,
          Object.keys(this.ypzcHcyFormData)
        )
      );
    },

    // 医疗器械核查员
    ylqxHcyFot(form) {
      this.ylqxHcyForm = form;
      this.ylqxHcyFormData = this.ylqxHcyFormData || {};
      this.ylqxHcyForm.setFieldsValue(
        this.lodash.pick(
          this.ylqxHcyFormData,
          Object.keys(this.ylqxHcyFormData)
        )
      );
    },

    // 化妆品核查员
    hzpHcyFot(form) {
      this.hzpHcyForm = form;
      this.hzpHcyFormData = this.hzpHcyFormData || {};
      this.hzpHcyForm.setFieldsValue(
        this.lodash.pick(this.hzpHcyFormData, Object.keys(this.hzpHcyFormData))
      );
    },

    // 获取基本数据
    async inspectorMessage() {
      this.spinning = true;
      const res = await queryMyJbxx(this.inspectorId);
      //console.log('获取基本数据',res);
      if (res.success) {
        const {
          hzpZj,
          ylqxZj,
          ypltZj,
          ypscZj,
          ypzcZj,
          hzpPsy,
          ylqxPsy,
          ypzcPsy,
          ypltPsy,
          user,
          ypscHcy,
          ypltHcy,
          ypzcHcy,
          ylqxHcy,
          hzpHcy,
          ypscPsy,
        } = res.result;
        this.userId = user["id"];
        user.sex = String(user.sex)
        this.formData = user;
        this.ypscHcyformData = ypscHcy;
        this.ypltHcyFormData = ypltHcy;
        this.ypzcHcyFormData = ypzcHcy;
        this.ylqxHcyFormData = ylqxHcy;
        this.hzpHcyFormData = hzpHcy;
        this.ypscPsyData = ypscPsy;
        this.ypltPsyData = ypltPsy;
        this.ypzcPsyData = ypzcPsy;
        this.ylqxPsyData = ylqxPsy;
        this.hzpPsyData = hzpPsy;
        this.hzpZjData = hzpZj;
        this.ylqxZjData = ylqxZj;
        this.ypltZjData = ypltZj;
        this.ypscZjData = ypscZj;
        this.ypzcZjData = ypzcZj;
        this.spinning = false;
        this.form.setFieldsValue(
          this.lodash.pick(this.formData, Object.keys(this.formData))
        );
        this.inspectorKey = Date.now()
      } else {
        this.spinning = false;
      }
    },
    // 更新保存用户数据
    saveUser() {
      var that = this
      this.form.validateFields((error, values) => {
        //console.log(values)
        //console.log(error)
        
        if (!error) {
          this.spinning = true;
          const formData = Object.assign(values, { id: this.inspectorId.fuserid?this.inspectorId.fuserid:this.userId});
          //console.log(formData);
          updateUser({...formData})
            .then((res) => {
              if (res.success) {
                this.$message.success(res.message);
                this.inspectorMessage();
              } else {
                this.$message.error(res.message);
              }
              this.spinning = false;
            })
            .catch((error) => {
              //console.log(error)
              this.$message.error("未知异常");
              this.spinning = false;
            });
        }
      });
    },

    //更新核查员信息
    saveHcy(form, hycid) {
      form.validateFields((error, values) => {
        if (!error) {
          //console.log(values)
          this.spinning = true;
          const formData = Object.assign(values, { id: hycid["id"], fszly:values.fszly && Array.isArray(values.fszly)?values.fszly.join(','):values.fszly});
          //console.log(formData);
          updateHcy(formData)
            .then((res) => {
              if (res.success) {
                this.$message.success(res.message);
                this.inspectorMessage();
              } else {
                this.$message.error(res.message);
              }
              this.spinning = false;
            })
            .catch((error) => {
              this.$message.error("未知异常");
              this.spinning = false;
            });
        }
      });
    },

    // 获取选派记录
    // queryMyXpjlList() {
    // }
    // 添加
    handleAdd(toobar, form, vId, callback) {
      //console.log(toobar, form, vId);
      //console.log(this.inspectorId.fuserid);
      if (vId.indexOf("培训记录") !== -1) {
        form.validateFields((error, values) => {
          if (!error) {
            if(this.inspectorId.fuserid){
              values = {
                ...values,
                id:this.inspectorId.id,
                fuserid:this.inspectorId.fuserid
              }
            }
            this.handlerAxios(sysAddPxjl, {...values}, callback);
            this.config.toobar.modalConfig.visabled = false;
          }
        });
      } else if (vId.indexOf("教育经历") !== -1) {
        form.validateFields((error, values) => {
          if (!error) {
            if(this.inspectorId.fuserid){
              values = {
                ...values,
                id:this.inspectorId.id,
                fuserid:this.inspectorId.fuserid
              }
            }
            this.handlerAxios(JyAddPxjl, {...values}, callback);
            this.config.toobar.modalConfig.visabled = false;
          }
        });
      } else if (vId.indexOf("工作经历") !== -1) {
        form.validateFields((error, values) => {
          if (!error) {
            if(this.inspectorId.fuserid){
              values = {
                ...values,
                id:this.inspectorId.id,
                fuserid:this.inspectorId.fuserid
              }
            }
            this.handlerAxios(GzAddPxjl, {...values}, callback);
            this.config.toobar.modalConfig.visabled = false;
          }
        });
      } else if (vId.indexOf("奖惩情况") !== -1) {
        form.validateFields((error, values) => {
          if (!error) {
            const formdata = Object.assign(values, {
              userId: this.formData.id,
              id: this.userId,
            });
            if(this.inspectorId.fuserid){
              formdata = {
                ...formdata,
                id:this.inspectorId.id,
                fuserid:this.inspectorId.fuserid
              }
            }
            //console.log(formdata);
            this.handlerAxios(sysUserJlcfqkAdd, {...formdata}, callback);
            this.config.toobar.modalConfig.visabled = false;
          }
        });
      }
    },
    // 添加-打开模态框
    handleaddOpen(toobar, vId = "") {
      //console.log(toobar, vId);
      if (vId.indexOf("培训记录") !== -1) {
        this.config.toobar.formItem = this.sysQueryForm;
      } else if (vId.indexOf("教育经历") !== -1) {
        this.config.toobar.formItem = this.JyQueryForm;
      } else if (vId.indexOf("工作经历") !== -1) {
        this.config.toobar.formItem = this.GzQueryForm;
      } else if (vId.indexOf("奖惩情况") !== -1) {
        this.config.toobar.formItem = this.sysUserJlcfqkForm;
      }
    },
    // 根据id查询数据
    async handlerQueryById(vId, row) {
      this.vxModal.id = vId;
      this.fid = row.id;
      if (vId.indexOf("培训记录") !== -1) {
        const res = await sysQueryById(row.id);
        if (res.success) {
          this.vxModal.visabled = true;
          this.callback(() => {
            //console.log(this.lodash.pick(res.result, Object.keys(res.result)));
            this.$refs.editform.form.setFieldsValue(
              this.lodash.pick(res.result, Object.keys(res.result))
            );
          }, 10);
        }
        // 查看培训记录-相关文件
        this.uploadPxjlFileid = row.id
        const resA = await queryPxjlFileList(row.id);
        //console.log('resA',resA)
        if(resA.success){
          this.filesListData = []
          this.filesListData = resA.result
          // //console.log('8888888',this.filesListData)
        }
      } else if (vId.indexOf("工作经历") !== -1) {
        const res = await GzQueryById(row.id);
        if (res.success) {
          this.vxModal.visabled = true;
          this.callback(() => {
            //console.log(this.lodash.pick(res.result, Object.keys(res.result)));
            this.$refs.editform.form.setFieldsValue(
              this.lodash.pick(res.result, Object.keys(res.result))
            );
          }, 10);
        }
      } else if (vId.indexOf("教育经历") !== -1) {
        const res = await JyQueryById(row.id);
        if (res.success) {
          this.vxModal.visabled = true;
          this.callback(() => {
            this.$refs.editform.form.setFieldsValue(
              this.lodash.pick(res.result, Object.keys(res.result))
            );
          }, 10);
        }
      } else if (vId.indexOf("奖惩情况") !== -1) {
        const res = await exportUserJlcfqkQueryById(row.id);
        if (res.success) {
          this.vxModal.visabled = true;
          this.callback(() => {
            this.$refs.editform.form.setFieldsValue(
              this.lodash.pick(res.result, Object.keys(res.result))
            );
          }, 10);
        }
      }
    },
    // 上传原本接口取消
    segmentBeforeUpload(e){
      return false
    },
    // 培训记录-上传文件
    uploadClick({file}){
      var that = this
        if(typeof file.uid !== 'undefined') {
          const fileData = new FormData();
          fileData.append("file",file);
          fileData.append("id",this.uploadPxjlFileid);
          uploadPxjlFile(fileData).then(res => {
            // //console.log('fileData',res)
              if(res.code !== 200){
                  that.$message.warning('请上传pdf文件或者联系管理员!')
              }else{
                  // this.manualSuccess()
                  that.$message.success('上传成功')
                    queryPxjlFileList(this.uploadPxjlFileid).then(res => {
                      this.filesListData = []
                      this.filesListData = res.result
                    })
              }
          })
        }
    },
    // 下载
    downloadFiles(val){
      // //console.log('下载',val)
      var that = this
      var fileName = val.fwjxsmc+val.fwjlx
      getPxjlFile(val.id).then((data) => {
        // //console.log(data)
          if (!data) {
              that.$message.warning('文件下载失败')
              return
          }
          let url = window.URL.createObjectURL(new Blob([data], { type: blobType.type[blobType.suffix.indexOf(val.fwjlx)] }))
          let link = document.createElement('a')
          link.style.display = 'none'
          link.href = url
          link.setAttribute('download', fileName)
          document.body.appendChild(link)
          link.click()
          document.body.removeChild(link) //下载完成移除元素
          window.URL.revokeObjectURL(url) //释放掉blob对象
          // this.vxModal.visabled = false;
      })
    },
    // 删除
    ddeleteFiles(idd){
      deletePxjlFileById({id:idd}).then(res => {
        // //console.log(res)
        if(res.code == 200){
          this.$message.success('删除成功')
          queryPxjlFileList(this.uploadPxjlFileid).then(res => {
            this.filesListData = []
            this.filesListData = res.result
          })
        } else {
          this.$message.warning(res.message)
        }
      })
    },
    // 编辑
    handlerEdit(vId, row) {
      if (this.vxModal.id.indexOf("培训记录") !== -1) {
        this.$refs.editform.form.validateFields((error, values) => {
          if (!error) {
            values["id"] = this.fid;
            //console.log(values);
            this.handlerAxios(sysEditPxjl, values);
          }
        });
      } else if (this.vxModal.id.indexOf("工作经历") !== -1) {
        this.$refs.editform.form.validateFields((error, values) => {
          if (!error) {
            values["id"] = this.fid;
            //console.log(values);
            this.handlerAxios(GzEditPxjl, values);
          }
        });
      } else if (this.vxModal.id.indexOf("教育经历") !== -1) {
        this.$refs.editform.form.validateFields((error, values) => {
          if (!error) {
            values["id"] = this.fid;
            //console.log(values);
            this.handlerAxios(JyEditPxjl, values);
          }
        });
      } else if (this.vxModal.id.indexOf("奖惩情况") !== -1) {
        this.$refs.editform.form.validateFields((error, values) => {
          if (!error) {
            values["id"] = this.fid;
            //console.log(values);
            this.handlerAxios(sysUsereditJcqk, values);
          }
        });
      }
    },
    // 请求
    handlerAxios(fn, form, callback) {
      // return
      if (fn instanceof Function) {
        fn(form)
          .then((res) => {
            if (res.success) {
              this.$message.success(res.message);
              // this.$refs.comTable.getQueryList();
              if (callback instanceof Function) {
                callback();
              }
            } else {
              this.$message.error(res.message);
            }
          })
          .catch((error) => {
            this.$message.error("未知异常");
          });
      }
    },
    // 删除
    handlerDelete(vId, row, callback) {
      var that = this
      this.$confirm({
        title:'您确认要删除吗？',
        // icon: createVNode(ExclamationCircleOutlined),
        onOk() {
          if (vId.indexOf("培训记录") !== -1) {
            that.handlerAxios(sysDeleteBatch, row.id, callback);
          } else if (vId.indexOf("工作经历") !== -1) {
            that.handlerAxios(GzDeleteBatch, row.id, callback);
          } else if (vId.indexOf("教育经历") !== -1) {
            that.handlerAxios(JyDeleteBatch, row.id, callback);
          } else if (vId.indexOf("奖惩情况") !== -1) {
            that.handlerAxios(sysUserDeleteBatchJcqk, row.id, callback);
          }
        },
          
      });
      
    },
    // 获取数字字典
    async dictType() {
      return await dict({ dictName: "sex" });
    },
    callback(fn, time) {
      this.timeout = setTimeout(() => {
        if (fn instanceof Function) {
          fn(this.timeout);
        }
      }, time);
    },
    // 上传文件
    async clickUpdateFile(type = "", refresh = Function) {
      try {
        const { file } = await VXETable.readFile({
          types: ["xlsx", "xls"],
        });
        //console.log(file);
        const Formdata = new FormData();
        Formdata.append("file", file);
        if(this.inspectorId.fuserid){
          Formdata.append("id", this.inspectorId.fuserid);
          Formdata.append("fuserid", this.inspectorId.fuserid);
        }
        //console.log('传参',Formdata)
        if (type.indexOf("培训记录") !== -1) {
          this.handlerUpdate(sysImpPxjlData, Formdata, refresh);
        } else if (type.indexOf("工作经历") !== -1) {
          this.handlerUpdate(GzImpPxjlData, Formdata, refresh);
        } else if (type.indexOf("教育经历") !== -1) {
          this.handlerUpdate(JyImpPxjlData, Formdata, refresh);
        } else if (type.indexOf("奖惩情况") !== -1) {
          //console.log("奖惩情况", "没有可用接口");
          // this.handlerUpdate(JyImpPxjlData, Formdata, refresh);
        }
      } catch (e) {
        //console.log(e);
      }
    },
    // 上传用户签名
    async handlerUserSignature() {
      try {
        const { file } = await VXETable.readFile({
          types: ["png", "jpg"],
        });
        const Formdata = new FormData();
        Formdata.append("file", file);
        Formdata.append("id", this.inspectorId.fuserid);
        Formdata.append("fuserid", this.inspectorId.fuserid);
        this.handlerUpdate(userSignatureImport, Formdata);
      } catch (e) {
        //console.log(e);
      }
    },
    // 文件下载
    async clickDownloadFile(type, refresh = Function) {
      const Formdata = new FormData();
      if (type.indexOf("培训记录模板") !== -1) {
        this.handlerDowenlaod(
          sysDownUserPxjlTemplate,
          Formdata,
          "培训记录模板"
        );
      } else if (type.indexOf("工作经历模板") !== -1) {
        this.handlerDowenlaod(GzDownUserPxjlTemplate, Formdata, "工作经历模板");
      } else if (type.indexOf("教育经历模板") !== -1) {
        this.handlerDowenlaod(JyDownUserPxjlTemplate, Formdata, "教育经历模板");
      } else if (type.indexOf("培训记录") !== -1) {
        this.handlerDowenlaod(sysExportUserPxjlData, Formdata, "培训记录");
      } else if (type.indexOf("工作经历") !== -1) {
        this.handlerDowenlaod(GzExportUserPxjlData, Formdata, "工作经历");
      } else if (type.indexOf("教育经历") !== -1) {
        this.handlerDowenlaod(JyExportUserPxjlData, Formdata, "教育经历");
      } else if (type.indexOf("奖惩情况模板") !== -1) {
        this.handlerDowenlaod(exportUserJlcfqkData, Formdata, "奖惩情况模板");
      } else if (type.indexOf("奖惩情况") !== -1) {
        this.handlerDowenlaod(exportUserJlcfqkDataFile, Formdata, "奖惩情况");
      } else if (type.indexOf("个人签名") !== -1) {
        const filename = this.formData.realname || "";
        this.handlerDowenlaod(
          userSignatureDownload,
          Formdata,
          filename + "个人签名",
          "png"
        );
      }
    },
    // 文件上传判断
    handlerUpdate(callback, formData = {}, refresh = Function) {
      //console.log(callback, formData);
      if (callback instanceof Function) {
        callback(formData)
          .then((res) => {
            //console.log(res);
            if (res.success) {
              this.$message.success(res.message);
              if (refresh instanceof Function) {
                refresh();
              }
            } else {
              this.$message.error(res.message);
            }
          })
          .catch((error) => {
            //console.log(error);
            this.$message.success("未知异常");
          });
      }
    },
    // 文件下载请求
    handlerDowenlaod(callback, formData = {}, filename = "", type = "") {
      if (callback instanceof Function) {
        if(this.inspectorId.fuserid){
          formData = {
            ...formData,
            id:this.inspectorId.fuserid,
            fuserid:this.inspectorId.fuserid,
          }
        }
        callback(formData)
          .then((res) => {
            //console.log(res);
            VXETable.saveFile({
              filename: filename,
              type: type || "xlsx",
              content: res,
            });
          })
          .catch((error) => {
            //console.log(error);
          });
      }
    },

    // 评审员
    // 药品生产
    ypscPsyFormFor(form, type, id) {
      this[type] = form;
      //console.log(this[id]);
      if (this[id]) {
        this[type].setFieldsValue(
          this.lodash.pick(this[id], Object.keys(this[id]))
        );
      }
    },
    //重置密码
    modifyPassword(text,data,key){
      var that = this
        this.$confirm({
          title:'您确认要重置密码吗？',
          // icon: createVNode(ExclamationCircleOutlined),
          onOk() {
            modifyServe(data).then(res=>{
              if(res.code == 200){
                  that.$message.success(res.message)
              }else{
                  that.$message.warning(res.message)
              }
            })
          },
            
        });
        
    },
    modifyClick(text,data,key,dataKey,dictionaryType,form){
      //console.log(data)
      this.editInterfaceInfo = {
            title:text,
            data:data,
            key:key,
            dataKey:dataKey,
            dictionaryType:dictionaryType,
            formName:form?form:'',
        }
        this.separateKey = Date.now()
        this.separateVisible = true
        //console.log(this.editInterfaceInfo)
    },
    separateHandleOk(){
        if(!this.editInterfaceInfo.data[this.editInterfaceInfo.key][this.editInterfaceInfo.dataKey]){
          if(this.editInterfaceInfo.title == '账号'){
              this.$message.warning('请输入账号')
          }else{
              this.$message.warning('请选择'+this.editInterfaceInfo.title)
          }
        }else{
          var that = this
          this.$confirm({
              title:'您确认要修改'+that.editInterfaceInfo.title+'吗？',
              onOk() {
                //console.log('传参',that.editInterfaceInfo.data)
                  modifyServe(that.editInterfaceInfo.data).then(res=>{
                      if(res.code == 200){
                          that.separateVisible = false
                          that.inspectorMessage()
                          
                          that.$message.success(res.message)
                          that.$emit('handleOk')
                          if(that.editInterfaceInfo.formName){
                          }
                      }else{
                          that.$message.warning(res.message)
                      }
                  })
              },
              
          });
        }
    },
    separateHandleCancel(){
      //console.log('取消')
      this.separateVisible = false
    }
  },
  beforeDestroy() {
    if (this.timeout) clearTimeout(this.timeout);
  },

  
};
</script>

<style lang="less" scoped>
@import url("../assets/common.less");
.massage {
  .form {
    padding: 20px;
    display: flex;
    justify-content: space-between;
  }
}
.form-item-bottom-num{
  .ant-form-item{
    margin-bottom: 0 !important;
  }
}
.blue-btn{
    border: 1px solid #5ca3e5 !important;
    background-color: #5ca3e5 !important;
    color: #fff !important;
}
.red-btn{
    border: 1px solid #ed5565 !important;
    background-color: #ed5565 !important;
}
</style>
